package ex0.expressions.operations;

/**
 * Created with IntelliJ IDEA.
 * User: Roi
 * Date: 10/18/13
 */
public class PowerOperation extends BinaryOperation {

    public PowerOperation(Double firstVal, Double secondVal, String firstStr, String secondStr) {
        super(firstVal, secondVal, firstStr, secondStr);
    }

    @Override
    protected String getOperationType() {
        return "^";
    }

    @Override
    protected Double apply(Double first, Double second) {
        return Math.pow(first, second);
    }
}
